-
Notifications
You must be signed in to change notification settings - Fork 1.9k
Clarify path matching behavior in Express.js documentation #2036
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Clarify path matching behavior in Express.js documentation #2036
Conversation
✅ Deploy Preview for expressjscom-preview ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
🚦 Lighthouse Results (Mobile & Desktop)
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you for your contribution, just a small comment from my side.
Co-authored-by: Sebastian Beltran <[email protected]>
I’ve pushed the requested changes. Please let me know if anything else is needed |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, thanks @kushal4345!
Summary
Updated the path examples documentation to clarify that route matching in Express.js is exact by default, unless path patterns, wildcards, or regular expressions are used.
Details
Previously, the docs said “This will match paths starting with…”, which could be interpreted as matching partial strings (e.g.,
/abcde
) when usingapp.use('/abcd', ...)
. This is misleading because Express matches exact paths unless explicitly configured otherwise.Change
Fixes The Path examples documentation is misleading #1892